package net.huashitong.Indicators.utils;

import java.math.BigDecimal;
import java.util.Comparator;
import java.util.Map;

public class ComparatorUtils implements Comparator<Map> {



	@Override
	public int compare(Map o1, Map o2) {
		Double double1 = Double.parseDouble(o2.get("rank").toString());
		Double double2 = Double.parseDouble(o1.get("rank").toString());
		BigDecimal data1 = new BigDecimal(double1); 
		BigDecimal data2 = new BigDecimal(double2); 
		return data1.compareTo(data2);
	}

}
